<!DOCTYPE html>



  


<html class="theme-next pisces use-motion" lang="zh-Hans">
<head>
  <meta charset="UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>

<meta name="theme-color" content="#222">



  
  
    
    
  <script src="/clysheng.oschina.me/lib/pace/pace.min.js?v=1.0.2"></script>
  <link href="/clysheng.oschina.me/lib/pace/pace-theme-minimal.min.css?v=1.0.2" rel="stylesheet">







<meta http-equiv="Cache-Control" content="no-transform" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
















  
  
  <link href="/clysheng.oschina.me/lib/fancybox/source/jquery.fancybox.css?v=2.1.5" rel="stylesheet" type="text/css" />







<link href="/clysheng.oschina.me/lib/font-awesome/css/font-awesome.min.css?v=4.6.2" rel="stylesheet" type="text/css" />

<link href="/clysheng.oschina.me/css/main.css?v=5.1.3" rel="stylesheet" type="text/css" />


  <link rel="apple-touch-icon" sizes="180x180" href="/clysheng.oschina.me/images/apple-touch-icon-next.png?v=5.1.3">


  <link rel="icon" type="image/png" sizes="32x32" href="/clysheng.oschina.me/images/favicon-32x32-next.png?v=5.1.3">


  <link rel="icon" type="image/png" sizes="16x16" href="/clysheng.oschina.me/images/favicon-16x16-next.png?v=5.1.3">


  <link rel="mask-icon" href="/clysheng.oschina.me/images/logo.svg?v=5.1.3" color="#222">





  <meta name="keywords" content="Hexo, NexT" />










<meta name="description" content="再牛逼的梦想，也抵不过傻逼式的坚持">
<meta property="og:type" content="website">
<meta property="og:title" content="Harvey&#39;s blog">
<meta property="og:url" content="http://clysheng.gitee.io/index.html">
<meta property="og:site_name" content="Harvey&#39;s blog">
<meta property="og:description" content="再牛逼的梦想，也抵不过傻逼式的坚持">
<meta property="og:locale" content="zh-Hans">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="Harvey&#39;s blog">
<meta name="twitter:description" content="再牛逼的梦想，也抵不过傻逼式的坚持">



<script type="text/javascript" id="hexo.configurations">
  var NexT = window.NexT || {};
  var CONFIG = {
    root: '/clysheng.oschina.me/',
    scheme: 'Pisces',
    version: '5.1.3',
    sidebar: {"position":"left","display":"post","offset":12,"b2t":false,"scrollpercent":false,"onmobile":false},
    fancybox: true,
    tabs: true,
    motion: {"enable":true,"async":false,"transition":{"post_block":"fadeIn","post_header":"slideDownIn","post_body":"slideDownIn","coll_header":"slideLeftIn","sidebar":"slideUpIn"}},
    duoshuo: {
      userId: '0',
      author: '博主'
    },
    algolia: {
      applicationID: 'AUMEJKQV9O',
      apiKey: '41a7b28b82fc9c14c1b4ffa6173ff625',
      indexName: 'harveyblog',
      hits: "",
      labels: ""
    }
  };
</script>



  <link rel="canonical" href="http://clysheng.gitee.io/"/>





  <title>Harvey's blog</title>
  








</head>

<body itemscope itemtype="http://schema.org/WebPage" lang="zh-Hans">

  
  
    
  

  <div class="container sidebar-position-left 
  page-home">
    <div class="headband"></div>

    <header id="header" class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-brand-wrapper">
  <div class="site-meta ">
    

    <div class="custom-logo-site-title">
      <a href="/clysheng.oschina.me/"  class="brand" rel="start">
        <span class="logo-line-before"><i></i></span>
        <span class="site-title">Harvey's blog</span>
        <span class="logo-line-after"><i></i></span>
      </a>
    </div>
      
        <p class="site-subtitle">无论工作多忙，计划都要坚持</p>
      
  </div>

  <div class="site-nav-toggle">
    <button>
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
    </button>
  </div>
</div>

<nav class="site-nav">
  

  
    <ul id="menu" class="menu">
      
        
        <li class="menu-item menu-item-home">
          <a href="/clysheng.oschina.me/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-home"></i> <br />
            
            首页
          </a>
        </li>
      
        
        <li class="menu-item menu-item-tags">
          <a href="/clysheng.oschina.me/tags/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-tags"></i> <br />
            
            标签
          </a>
        </li>
      
        
        <li class="menu-item menu-item-categories">
          <a href="/clysheng.oschina.me/categories/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-th"></i> <br />
            
            分类
          </a>
        </li>
      
        
        <li class="menu-item menu-item-archives">
          <a href="/clysheng.oschina.me/archives/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-archive"></i> <br />
            
            归档
          </a>
        </li>
      

      
        <li class="menu-item menu-item-search">
          
            <a href="javascript:;" class="popup-trigger">
            
              <i class="menu-item-icon fa fa-search fa-fw"></i> <br />
            
            搜索
          </a>
        </li>
      
    </ul>
  

  
    <div class="site-search">
      
  
  <div class="algolia-popup popup search-popup">
    <div class="algolia-search">
      <div class="algolia-search-input-icon">
        <i class="fa fa-search"></i>
      </div>
      <div class="algolia-search-input" id="algolia-search-input"></div>
    </div>

    <div class="algolia-results">
      <div id="algolia-stats"></div>
      <div id="algolia-hits"></div>
      <div id="algolia-pagination" class="algolia-pagination"></div>
    </div>

    <span class="popup-btn-close">
      <i class="fa fa-times-circle"></i>
    </span>
  </div>




    </div>
  
</nav>



 </div>
    </header>

    <main id="main" class="main">
      <div class="main-inner">
        <div class="content-wrap">
          <div id="content" class="content">
            
  <section id="posts" class="posts-expand">
    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2018/01/10/如何阅读一本书/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2018/01/10/如何阅读一本书/" itemprop="url">如何阅读一本书</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2018-01-10T21:00:00+08:00">
                2018-01-10
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/读书笔记/" itemprop="url" rel="index">
                    <span itemprop="name">读书笔记</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h2 id="读书的四层境界"><a href="#读书的四层境界" class="headerlink" title="读书的四层境界"></a>读书的四层境界</h2><ul>
<li>基础阅读<br>快速浏览，不管能不能读懂，知道在说什么就行</li>
<li><p>检视阅读<br>用最少的时间了解书在说什么，书的结构，包含部分，分类，以及作者意图<br>分为两种：</p>
<ul>
<li>有系统的略读或粗读<br>最少的时间找到这本书的主题或思想线索，包括书名，标题，序言，目录，索引，然后从目录里挑选一些跟主题息息相关的章节来看，然后打开书随便看一下，或者挑一些阅读下</li>
<li>粗浅的阅读<br>重点在于不停顿，哪怕读到看不懂的地方也不要停下来查资料，直接忽略掉，重点放在自己能看懂的地方，哪怕最终只读懂了书里面一小部分，但是没有关系，起码已经读懂了这些，<strong><em>享受阅读的乐趣是学会的前提</em></strong></li>
</ul>
</li>
<li><p>分析阅读<br>把一本书看透，嚼烂和消化书中内容</p>
</li>
<li>主题阅读<br>读的不是书而是主题，同时阅读某个主题的多本书</li>
</ul>
<h2 id="阅读的时候要提出四个基本的问题"><a href="#阅读的时候要提出四个基本的问题" class="headerlink" title="阅读的时候要提出四个基本的问题"></a>阅读的时候要提出四个基本的问题</h2><ul>
<li>整体来看这本书在说什么</li>
<li>作者细节上说了什么</li>
<li>说的有道理吗，是部分还是全部</li>
<li>这本书和你有关系吗</li>
</ul>
<h2 id="分析阅读"><a href="#分析阅读" class="headerlink" title="分析阅读"></a>分析阅读</h2><h3 id="分类"><a href="#分类" class="headerlink" title="分类"></a>分类</h3><p>阅读之前一定要知道自己在读的是哪一类书，学会如何分类，可以简单把书分为小说类和论说类，或者理论性作品刚和实用型作品</p>
<h3 id="透视一本书"><a href="#透视一本书" class="headerlink" title="透视一本书"></a>透视一本书</h3><ul>
<li>寻找书的骨架</li>
<li>使用单一的句子，或最多几句话来叙述整本书的内容</li>
<li>将书中重要的篇章列举出来，并能说明他们是如何按照一定的顺序组成一个架构的</li>
<li>找出作者要问的问题或者要解决的问题</li>
<li>找出重要的单字，并透过他们与作者达成共识</li>
<li>将一本书重要的句子圈出来，找出其中主旨</li>
<li>从相关的关联中，设法架构出一本书的基础论述</li>
<li>找出作者解答</li>
<li>在评论之前一定能肯定的说我了解了</li>
<li>不同意作者观点要理性表达自己意见，不辩驳，不争论</li>
<li>尊重知识和个人观点，做任何判断前，要找到理论依据</li>
</ul>
<h2 id="如何阅读各种类型书籍"><a href="#如何阅读各种类型书籍" class="headerlink" title="如何阅读各种类型书籍"></a>如何阅读各种类型书籍</h2><h3 id="如何阅读实用型书"><a href="#如何阅读实用型书" class="headerlink" title="如何阅读实用型书"></a>如何阅读实用型书</h3><ul>
<li>检查作者是否提出了合理可执行，并且效果可检查的方法是分辨是否是实用类书籍的一个方法。</li>
<li>实际问题只能靠行动来解决，看完不行动，那看的就是鸡汤</li>
</ul>
<h3 id="如何阅读想象文学"><a href="#如何阅读想象文学" class="headerlink" title="如何阅读想象文学"></a>如何阅读想象文学</h3><ul>
<li>不要抗拒想象文学带给你的影响力</li>
<li>不要去找共识，主旨和论述</li>
</ul>
<h3 id="如何阅读故事书-小说"><a href="#如何阅读故事书-小说" class="headerlink" title="如何阅读故事书(小说)"></a>如何阅读故事书(小说)</h3><ul>
<li>快速并且全心全意的读</li>
<li>不要太在意暂时的障碍，继续读下去，自然会柳暗花明</li>
</ul>
<h3 id="如何阅读史书和戏剧"><a href="#如何阅读史书和戏剧" class="headerlink" title="如何阅读史书和戏剧"></a>如何阅读史书和戏剧</h3><ul>
<li>主动，集中注意力的阅读</li>
<li>运用更多的想象力</li>
<li>最好一口气读完</li>
</ul>
<h3 id="如何阅读抒情诗"><a href="#如何阅读抒情诗" class="headerlink" title="如何阅读抒情诗"></a>如何阅读抒情诗</h3><ul>
<li>一口气读完</li>
<li>重复，大声读出来</li>
<li>了解一首诗最好的方式就是一遍遍的去读它</li>
</ul>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2018/01/10/同时发布到Coding和GitHub的方法/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2018/01/10/同时发布到Coding和GitHub的方法/" itemprop="url">同时发布到Coding和GitHub的方法</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2018-01-10T14:40:00+08:00">
                2018-01-10
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/Hexo/" itemprop="url" rel="index">
                    <span itemprop="name">Hexo</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            
          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2018/01/09/java8 Optional.1/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2018/01/09/java8 Optional.1/" itemprop="url">Optional</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2018-01-09T09:30:00+08:00">
                2018-01-09
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/java8/" itemprop="url" rel="index">
                    <span itemprop="name">java8</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h2 id="null引发的问题"><a href="#null引发的问题" class="headerlink" title="null引发的问题"></a>null引发的问题</h2><p>null最常见带来的问题就是<strong><em>NullPointerException</em></strong>，即使在我们认为可能出现null的地方加上if语句判断，任然会频发的和它打交道，而且还会代码出现很多的if嵌套，被它的概念提出者Tony Hoare称之为价值百万的失误</p>
<h2 id="Optional的作用"><a href="#Optional的作用" class="headerlink" title="Optional的作用"></a>Optional的作用</h2><p>能非常清晰地界定出变量值的缺失是结构上的问题，还是你算法上的缺陷，抑或是你数据中的问题。另外，我们还想特别强调，引入Optional 类的意图并非要消除每一个null引用。与此相反，它的目标是帮助你更好地设计出普适的API， 让程序员看到方法签名，就能了解它是否接受一个Optional的值。这种强制会让你更积极地将 变量从Optional中解包出来，直面缺失的变量值。</p>
<h2 id="如何使用"><a href="#如何使用" class="headerlink" title="如何使用"></a>如何使用</h2><h3 id="创建Optional对象"><a href="#创建Optional对象" class="headerlink" title="创建Optional对象"></a>创建Optional对象</h3><h4 id="声明一个空的Optional"><a href="#声明一个空的Optional" class="headerlink" title="声明一个空的Optional"></a>声明一个空的Optional</h4><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">Optional&lt;Car&gt; car = Optional.empty() ;</span><br></pre></td></tr></table></figure>
<h4 id="依据一个非空值创建Optional"><a href="#依据一个非空值创建Optional" class="headerlink" title="依据一个非空值创建Optional"></a>依据一个非空值创建Optional</h4><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><span class="line">Car car = null ;</span><br><span class="line">Optional&lt;Car&gt; carOpt = Optional.of(car) ;</span><br></pre></td></tr></table></figure>
<p>如果car是一个空值，这段代码会立即抛出<strong><em>NullPointerException</em></strong>，而不是等到试图访问car属性的时候</p>
<h4 id="可接受null的Optional"><a href="#可接受null的Optional" class="headerlink" title="可接受null的Optional"></a>可接受null的Optional</h4><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><span class="line">Car car = null ;</span><br><span class="line">Optional&lt;Car&gt; carOpt = Optional.ofNullable(car) ;</span><br></pre></td></tr></table></figure>
<p>如果car是空那么carOpt就是一个空对象，获取对象中的值的时候依然会抛出异常</p>
<h3 id="一点注意"><a href="#一点注意" class="headerlink" title="一点注意"></a>一点注意</h3><p>Optional在设计的时候没有考虑做为类的字段使用，所以它并未实现序列化接口，所以某些要求序列的库或框架中使用Optional有可能会引发应用故障<br></p>
<h2 id="常用API"><a href="#常用API" class="headerlink" title="常用API"></a>常用API</h2><table>
<thead>
<tr>
<th>方法</th>
<th style="text-align:center">描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>empty</td>
<td style="text-align:center">返回一个空的 Optional 实例</td>
</tr>
<tr>
<td>flatMap</td>
<td style="text-align:center">如果值存在，就对该值执行提供的 mapping 函数调用，返回一个 Optional 类型的值，否则就返回一个空的 Optional 对象</td>
</tr>
<tr>
<td>get</td>
<td style="text-align:center">如果该值存在，将该值用 Optional 封装返回，否则抛出一个 NoSuchElementException 异常</td>
</tr>
<tr>
<td>ifPresent</td>
<td style="text-align:center">如果值存在，就执行使用该值的方法调用，否则什么也不做</td>
</tr>
<tr>
<td>isPresent</td>
<td style="text-align:center">如果值存在就返回 true，否则返回 false</td>
</tr>
<tr>
<td>map</td>
<td style="text-align:center">如果值存在，就对该值执行提供的 mapping 函数调用</td>
</tr>
<tr>
<td>of</td>
<td style="text-align:center">将指定值用 Optional 封装之后返回，如果该值为 null，则抛出一个 NullPointerException 异常</td>
</tr>
<tr>
<td>ofNullable</td>
<td style="text-align:center">将指定值用 Optional 封装之后返回，如果该值为 null，则返回一个空的 Optional 对象</td>
</tr>
<tr>
<td>orElse</td>
<td style="text-align:center">如果有值则将其返回，否则返回一个默认值</td>
</tr>
<tr>
<td>orElseGet</td>
<td style="text-align:center">如果有值则将其返回，否则返回一个由指定的 Supplier 接口生成的值</td>
</tr>
<tr>
<td>orElseThrow</td>
<td style="text-align:center">如果有值则将其返回，否则抛出一个由指定的 Supplier 接口生成的异常</td>
</tr>
</tbody>
</table>
<h2 id="实战例子"><a href="#实战例子" class="headerlink" title="实战例子"></a>实战例子</h2><p>返回一个正整数，如果小于0或者不存在则返回0<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br></pre></td><td class="code"><pre><span class="line">Properties properties = new Properties() ;</span><br><span class="line">properties.put(&quot;a&quot;,1) ;</span><br><span class="line">properties.put(&quot;b&quot;,-5) ;</span><br><span class="line">properties.put(&quot;c&quot;,1) ;</span><br><span class="line"></span><br><span class="line"> public int getValueOptional(Properties properties,String name)&#123;</span><br><span class="line">    return Optional.ofNullable(properties.getProperty(name)).flatMap(OptionalTest::stringToInt).filter(i -&gt; i&gt;0).orElse(0) ;</span><br><span class="line">&#125;</span><br><span class="line">public static Optional&lt;Integer&gt; stringToInt(String s) &#123;</span><br><span class="line">    try &#123;</span><br><span class="line">        return Optional.of(Integer.parseInt(s));</span><br><span class="line">    &#125; catch (NumberFormatException e) &#123;</span><br><span class="line">        return Optional.empty();</span><br><span class="line">    &#125;</span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure></p>
<p>通过这个例子可以看出，Optional加入丰富了语意，减少了之前很多不必要的if判断，代码更简洁直观</p>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2018/01/06/工作中一次触发器的使用/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2018/01/06/工作中一次触发器的使用/" itemprop="url">工作中一次触发器的使用</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2018-01-06T20:00:00+08:00">
                2018-01-06
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/工作/" itemprop="url" rel="index">
                    <span itemprop="name">工作</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h4 id="需求"><a href="#需求" class="headerlink" title="需求"></a>需求</h4><p> 本周五要下班的时候，客服那边突然提出了一个紧急问题，一个用户，因为最近家里面和老婆闹矛盾，正巧在我们平台投了一些私房钱，所以这段时间就不想收到平台发给她的回款短信，担心他老婆知道了，马上就周末了，毕竟又是特例，就不想在代码里面去做修改，所以就想到了触发器，我们服务器使用的是mysql，思路就是向数据库插入短信队列消息的时候，判断是不是这个客户的手机号，如果是就将短信状态置为一个不被队列扫描的状态，</p>
<h4 id="实现"><a href="#实现" class="headerlink" title="实现"></a>实现</h4><p> 具体代码如下<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br></pre></td><td class="code"><pre><span class="line">CREATE TRIGGER triggerName</span><br><span class="line">BEFORE INSERT ON tableName</span><br><span class="line">FOR EACH ROW</span><br><span class="line">BEGIN</span><br><span class="line">  if (NEW.phone=&apos;xxx&apos;)</span><br><span class="line">    THEN</span><br><span class="line">  set NEW.deal_flag=1 ;</span><br><span class="line">    end if;</span><br><span class="line">END</span><br></pre></td></tr></table></figure></p>
<h4 id="在创建触发器时，需要给出4条信息："><a href="#在创建触发器时，需要给出4条信息：" class="headerlink" title="在创建触发器时，需要给出4条信息："></a>在创建触发器时，需要给出4条信息：</h4><ul>
<li>唯一的触发器名；</li>
<li>触发器关联的表</li>
<li>触发器应该响应的动作（ DELETE、INSERT 或UPDATE）</li>
<li>触发器何时执行（处理之前或之后）。</li>
</ul>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2018/01/06/java8默认方法/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2018/01/06/java8默认方法/" itemprop="url">java8默认方法</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2018-01-06T09:30:00+08:00">
                2018-01-06
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/java8/" itemprop="url" rel="index">
                    <span itemprop="name">java8</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h2 id="什么是默认方法"><a href="#什么是默认方法" class="headerlink" title="什么是默认方法"></a>什么是默认方法</h2><p>java8以前，接口中所有的方法必须为抽象方法，java8允许接口在声明方法的同时提供实现，通过两种方式可以完成这种操作</p>
<ul>
<li>接口内申明静态方法</li>
<li>为接口引用方法提供一个默认的实现 </li>
</ul>
<p>意思就是，你可以为接口提供具体的实现</p>
<h2 id="为什么引入默认方法"><a href="#为什么引入默认方法" class="headerlink" title="为什么引入默认方法"></a>为什么引入默认方法</h2><p>在以往，为接口添加方法会引发很多的改动，因为你的接口可能已经有了很多的实现类，为接口添加方法，所有的实现类都要实现它，显然是不能被接受的，但是默认方法的引入为接口的功能扩展提供了一个平滑的过度，如果你是一个类库的设计者，那么你可以放心的改进应用程序接口，无需担心遗留代码的影响</p>
<h2 id="如何实现"><a href="#如何实现" class="headerlink" title="如何实现"></a>如何实现</h2><p>默认方法是由default修饰，并像类中声明的其它方法一样具有方法体，例如<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br></pre></td><td class="code"><pre><span class="line">public interface Sized &#123;</span><br><span class="line">    int size();</span><br><span class="line">    default boolean isEmpty() &#123;</span><br><span class="line">        return size() == 0;</span><br><span class="line">    &#125; </span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure></p>
<p>那么所有继承Sized类都会默认继承了<strong><em>isEmpty</em></strong>方法，而不用去实现它，如果想扩展该方法，可以重写它</p>
<h2 id="行为多继承"><a href="#行为多继承" class="headerlink" title="行为多继承"></a>行为多继承</h2><p>默认方法的引入，让java8可以实现行为的多继承，这是以前无法想象的事情，它让类具有可以从多个来源重用代码的能力</p>
<blockquote>
<p> 继承不应该成为你一谈到代码复用就试图倚靠的万精油。比如，从一个拥有100个方法及 字段的类进行继承就不是个好主意，因为这其实会引入不必要的复杂性。你完全可以使用代理 有效地规避这种窘境，即创建一个方法通过该类的成员变量直接调用该类的方法。这就是为什 么有的时候我们发现有些类被刻意地声明为final类型:声明为final的类不能被其他的类继 承，避免发生这样的反模式，防止核心代码的功能被污染。注意，有的时候声明为final的类 都会有其不同的原因，比如，String类被声明为final，因为我们不希望有人对这样的核心 功能产生干扰。这种思想同样也适用于使用默认方法的接口。通过精简的接口，你能获得最有效的组合，因为你可以只选择你需要的实现。</p>
</blockquote>
<h2 id="解决冲突规则"><a href="#解决冲突规则" class="headerlink" title="解决冲突规则"></a>解决冲突规则</h2><p>随着默认方法的引入，现在有可能一个类实现了多个接口，它们具有相同的函数签名，例如<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br></pre></td><td class="code"><pre><span class="line">public interface A &#123;</span><br><span class="line">    default void hello() &#123;</span><br><span class="line">        System.out.println(&quot;Hello from A&quot;);</span><br><span class="line">    &#125;</span><br><span class="line">&#125;</span><br><span class="line">public interface B extends A &#123;</span><br><span class="line">    default void hello() &#123;</span><br><span class="line">        System.out.println(&quot;Hello from B&quot;);</span><br><span class="line">&#125; &#125;</span><br><span class="line">public class C implements B, A &#123;</span><br><span class="line">    public static void main(String... args) &#123;</span><br><span class="line">        new C().hello();</span><br><span class="line">    &#125;</span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure></p>
<p>这种情况类会使用哪一个方法呢，这个问题其实就是菱形继承的问题，一个类同时具有相同函数签名的方法，到底选择哪一种实现，java8为了解决这种问题引入了三条规则</p>
<ol>
<li>类中的方法优先级最高。类或父类声明的方法优先级高于任何声明默认方法的优先级。</li>
<li>如果无法依据第一条进行判断，那么子接口的优先级更高，函数签名相同时，优先选择拥有具体实现的默认方法接口，如果B继承了A，那么B就比A更具体。</li>
<li>如果上述两条规则还是无法判断，继承了多个接口的类必须通过显示覆盖和调用期望方法，显式的选择使用哪一个默认方法实现。</li>
</ol>
<p>根据这三条规则，上面的例子可以对照第二条规则，因为B继承了所以B更具体，那么结果打印出来就是<strong><em>Hello From B</em></strong></p>
<h2 id="java8中接口与抽像类的区别"><a href="#java8中接口与抽像类的区别" class="headerlink" title="java8中接口与抽像类的区别"></a>java8中接口与抽像类的区别</h2><p>现在java8中接口可以有具体的方法，那么他们之间的区别还有哪些</p>
<ul>
<li>一个类只能继承一个抽象类，但是一个类可以继承多个接口</li>
<li>一个抽象类可以通过实例变量保存一个通用的状态，但是接口不能</li>
</ul>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2018/01/01/Next主题美化/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2018/01/01/Next主题美化/" itemprop="url">next主题美化</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2018-01-01T20:08:00+08:00">
                2018-01-01
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/Hexo/" itemprop="url" rel="index">
                    <span itemprop="name">Hexo</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h2 id="修改背景"><a href="#修改背景" class="headerlink" title="修改背景"></a>修改背景</h2><p>如果觉得next默认主题的背景颜色太单调，可以自己手动去替换,将下段内容<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br></pre></td><td class="code"><pre><span class="line">body &#123; </span><br><span class="line">    background:url(/images/background-1.jpeg);</span><br><span class="line">    background-attachment: fixed;</span><br><span class="line"></span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure></p>
<p>粘贴到themes/next/source/css/_custom/custom.styl下面，不需要直接去修改系统文件，next支持用户自主扩展</p>
<h2 id="添加搜索"><a href="#添加搜索" class="headerlink" title="添加搜索"></a>添加搜索</h2><p>当前主题为next5.1.3版本，选择algolia做为站内搜索<br>安装教程可以参考<a href="http://theme-next.iissnan.com/third-party-services.html#search-system" target="_blank" rel="noopener">官方文档</a><br>需要注意的是，按照文档完成之后，可以在algolia网站进行测试<br><img src="https://ws3.sinaimg.cn/large/006tNc79gy1fn78fnnlrcj31ja0pi3zk.jpg" alt=""><br>但是不管是搜索title，还是tag都搜索不到任何信息，经过多次测试发现默认是按着name匹配<br>可以在下图处添加匹配字段<br><img src="https://ws4.sinaimg.cn/large/006tNc79gy1fn78j9qmy6j31fs0qo0tm.jpg" alt=""><br>而且可以调整匹配顺序，最终测试可以搜索到</p>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2018/01/01/2018计划清单/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2018/01/01/2018计划清单/" itemprop="url">2018计划清单</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2018-01-01T15:00:00+08:00">
                2018-01-01
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/计划/" itemprop="url" rel="index">
                    <span itemprop="name">计划</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h2 id="坚持运动"><a href="#坚持运动" class="headerlink" title="坚持运动"></a>坚持运动</h2><p>以周为单位，每周至少保持运动三次，跑步，羽毛球，篮球，爬山都算<br>每天早起坚持做至少二十个俯卧撑或者至少40个深蹲，数量少，贵在养成坚持的习惯<br>每三个月跑一个十公里</p>
<h2 id="坚持背单词"><a href="#坚持背单词" class="headerlink" title="坚持背单词"></a>坚持背单词</h2><p>完成百词斩计划，每天新记10个单词<br>每周读懂一篇英语短文<br>每个月记下一篇英语短文</p>
<h2 id="书单"><a href="#书单" class="headerlink" title="书单"></a>书单</h2><p>下面书籍为2018年想学习的书籍，每天至少保证工作时间外抽出时间学习一个小时</p>
<table>
<thead>
<tr>
<th>书名</th>
<th style="text-align:center">计划完成时间</th>
<th style="text-align:center">掌握情况</th>
</tr>
</thead>
<tbody>
<tr>
<td>java8实战</td>
<td style="text-align:center">2018-02-10</td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>spring-boot实战</td>
<td style="text-align:center">2018-03-10</td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>netty权威指南</td>
<td style="text-align:center">2018-05-10</td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>docker</td>
<td style="text-align:center">2018-06-10</td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>kafka</td>
<td style="text-align:center">2018-06-10</td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>高性能mysql</td>
<td style="text-align:center">2018-08-10</td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>spring-cloud</td>
<td style="text-align:center"></td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>大型网站技术架构</td>
<td style="text-align:center"></td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>深入理解jm</td>
<td style="text-align:center"></td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>Effective Java</td>
<td style="text-align:center"></td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>算法导论</td>
<td style="text-align:center"></td>
<td style="text-align:center"></td>
</tr>
<tr>
<td>把时间当做朋友</td>
<td style="text-align:center"></td>
</tr>
</tbody>
</table>
<p>除了上述书籍外，想增强的技术还有<br>redis，ngnix抽空看博客学习</p>
<h2 id="关于日常"><a href="#关于日常" class="headerlink" title="关于日常"></a>关于日常</h2><p>重要的物品养成放在指定地方的习惯，避免日常花费多余的时间找东西<br>养成早起的习惯，工作日六点起床，周末8点前起床的<br>无论工作多忙提醒自己，每天上午下午至少一杯水<br>学会炒菜，目标每两个月会一道菜<br>家里卫生每周至少一次</p>
<h2 id="坚持写博客"><a href="#坚持写博客" class="headerlink" title="坚持写博客"></a>坚持写博客</h2><p>养成写作的习惯，每个星期至少更新一篇博客，内容形式不限制，可以是技术学习笔记，也可以是生活感悟，也可以是喜欢内容摘抄，通过写作让自己变的不浮躁，养成思考的习惯</p>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2017/12/31/Hexo博客搭建/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2017/12/31/Hexo博客搭建/" itemprop="url">一. Hexo+github博客搭建</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2017-12-31T15:12:33+08:00">
                2017-12-31
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/Hexo/" itemprop="url" rel="index">
                    <span itemprop="name">Hexo</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h2 id="工具准备"><a href="#工具准备" class="headerlink" title="工具准备"></a>工具准备</h2><h3 id="安装git"><a href="#安装git" class="headerlink" title="安装git"></a>安装git</h3><p>点击下载最新版本的<a href="https://git-scm.com/downloads" target="_blank" rel="noopener">git</a></p>
<h3 id="安装Node-js"><a href="#安装Node-js" class="headerlink" title="安装Node.js"></a>安装Node.js</h3><p>Hexo是基于nodeJS环境的静态博客，所以需要下载nodejs，点击下载，然后一直安装，安装完成后可以通过<strong><em>node -v</em></strong>查看当前版本，检查是否安装成功</p>
<h3 id="安装hexo"><a href="#安装hexo" class="headerlink" title="安装hexo"></a>安装hexo</h3><p>现在本地新建一个文件夹，后面用来存放所有的blog的内容</p>
<ul>
<li>cd到该目录下</li>
<li>通过<strong><em>npm i -g hexo</em></strong>安装hexo</li>
<li>安装完成之后通过<strong><em>hexo -v</em></strong>查看当前版本</li>
<li>初始化命令<strong><em>hexo init</em></strong>,初始化完成后会在当前目录下生成以下文件<br><img src="https://ws2.sinaimg.cn/large/006tNc79ly1fn6qxpifwdj30p00ac3zy.jpg" alt=""></li>
<li>node_modules:依赖包</li>
<li>public：存放生成的页面</li>
<li>scaffolds：命令生成文档等的模板</li>
<li>source：用命令创建的各种文章</li>
<li>themes：主题</li>
<li>_config.yml：整个博客的配置</li>
<li>db.json：source解析所得到的</li>
<li>package.json：项目所需要模块配置信息</li>
</ul>
<hr>
<h2 id="链接到github"><a href="#链接到github" class="headerlink" title="链接到github"></a>链接到github</h2><h3 id="创建github账户"><a href="#创建github账户" class="headerlink" title="创建github账户"></a>创建github账户</h3><p> 点击去<a href="https://github.com/" target="_blank" rel="noopener">github</a>创建一个账户，如果有登录进去</p>
<h3 id="创建一个repository"><a href="#创建一个repository" class="headerlink" title="创建一个repository"></a>创建一个repository</h3><p><img src="https://ws1.sinaimg.cn/large/006tNc79ly1fn6qz2a90aj30iw09u74u.jpg" alt=""><br> <strong><em>仓库名字</em></strong><br><img src="https://ws4.sinaimg.cn/large/006tNc79ly1fn6r0ky6e7j30pe07kaaw.jpg" alt=""><br><strong><em>yourname</em></strong>与账户名最好一致，不然后面可能会导致页面css内容无法展示</p>
<h3 id="回到本地gitbash中，配置账户信息"><a href="#回到本地gitbash中，配置账户信息" class="headerlink" title="回到本地gitbash中，配置账户信息"></a>回到本地gitbash中，配置账户信息</h3><p>命令行输入<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><span class="line">git config --global user.name &quot;yourname&quot;</span><br><span class="line">git config --global user.email &quot;youremail&quot;</span><br></pre></td></tr></table></figure></p>
<h3 id="创建ssh"><a href="#创建ssh" class="headerlink" title="创建ssh"></a>创建ssh</h3><p>在gitbash中输入<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">ssh-keygen -t rsa -C &quot;youremail&quot;</span><br></pre></td></tr></table></figure></p>
<p>生成ssh文件，mac和linux用户在<strong><em>~/ssh</em></strong>下找到<strong><em>id_rsa.pub</em></strong>，复制文件里面内容</p>
<h3 id="将生成的内容粘贴到github"><a href="#将生成的内容粘贴到github" class="headerlink" title="将生成的内容粘贴到github"></a>将生成的内容粘贴到github</h3><ul>
<li>点击下图箭头setting<br><img src="https://ws2.sinaimg.cn/large/006tNc79ly1fn6r0xc3pxj30gc0femxy.jpg" alt=""></li>
<li>点击左侧菜单下图箭头指向栏目<br><img src="https://ws4.sinaimg.cn/large/006tNc79ly1fn6r1l0s23j30i8080t97.jpg" alt=""></li>
<li>点击右上角<br><img src="https://ws2.sinaimg.cn/large/006tNc79ly1fn6r1y6zikj309g032aa2.jpg" alt=""></li>
<li>将本机<strong><em>id_rsa.pub</em></strong>内容粘贴到key里面</li>
<li>检验是否添加成功，本地gitbash中输入<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">git -T git@github.com</span><br></pre></td></tr></table></figure>
</li>
</ul>
<h2 id="配置本地blog"><a href="#配置本地blog" class="headerlink" title="配置本地blog"></a>配置本地blog</h2><h3 id="更改配置文件"><a href="#更改配置文件" class="headerlink" title="更改配置文件"></a>更改配置文件</h3><p>用编辑器打开<strong><em>hexo init</em></strong>目录下的<strong><em>_config.yml</em></strong>配置文件<br><img src="https://ws2.sinaimg.cn/large/006tNc79ly1fn6r29a9gij30mk066753.jpg" alt=""><br><strong><em>repo</em></strong>为github上新建的项目地址</p>
<blockquote>
<p>注意所有的类型名称冒号后面一定要有空格</p>
<h3 id="预览本地blog"><a href="#预览本地blog" class="headerlink" title="预览本地blog"></a>预览本地blog</h3><p>hexo3.0把服务器独立成个别模块，需要单独安装<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">npm i hexo-server</span><br></pre></td></tr></table></figure></p>
</blockquote>
<p>然后执行以下命令<br>清除本地项目缓存<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">hexo clean</span><br></pre></td></tr></table></figure></p>
<p>生成最新项目<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">hexo generate(缩写 hexo g)</span><br></pre></td></tr></table></figure></p>
<p>启动hexo server<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">hexo server</span><br></pre></td></tr></table></figure></p>
<p>如果上述步奏全部正确，打开浏览器输入localhost:4000，就可以看到本地项目预览了</p>
<h2 id="上传到github"><a href="#上传到github" class="headerlink" title="上传到github"></a>上传到github</h2><p>要想blog被其他人也能访问到,就要上传到<strong>*github</strong><br>gitbash中执行<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">npm install hexo-deployer-git --save</span><br></pre></td></tr></table></figure></p>
<p>按着下列步骤将本地项目上传到<strong>*github</strong><br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><span class="line">hexo clean</span><br><span class="line">hexo generate</span><br><span class="line">hexo server</span><br></pre></td></tr></table></figure></p>
<h2 id="访问blog"><a href="#访问blog" class="headerlink" title="访问blog"></a>访问blog</h2><p>github中打开blog项目，点击setting<br><img src="https://ws2.sinaimg.cn/large/006tNc79ly1fn6r2qwr81j31fe05wwfo.jpg" alt=""><br>下列箭头指向的即为blog访问地址<br><img src="https://ws2.sinaimg.cn/large/006tNc79ly1fn6r3d59axj31b40b6jt3.jpg" alt=""></p>
<p>至此大功告成</p>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2017/12/30/hello-world/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2017/12/30/hello-world/" itemprop="url">Hello World</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2017-12-30T09:58:33+08:00">
                2017-12-30
              </time>
            

            

            
          </span>

          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <p>Welcome to <a href="https://hexo.io/" target="_blank" rel="noopener">Hexo</a>! This is your very first post. Check <a href="https://hexo.io/docs/" target="_blank" rel="noopener">documentation</a> for more info. If you get any problems when using Hexo, you can find the answer in <a href="https://hexo.io/docs/troubleshooting.html" target="_blank" rel="noopener">troubleshooting</a> or you can ask me on <a href="https://github.com/hexojs/hexo/issues" target="_blank" rel="noopener">GitHub</a>.</p>
<h2 id="Quick-Start"><a href="#Quick-Start" class="headerlink" title="Quick Start"></a>Quick Start</h2><h3 id="Create-a-new-post"><a href="#Create-a-new-post" class="headerlink" title="Create a new post"></a>Create a new post</h3><figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">$ hexo new <span class="string">"My New Post"</span></span><br></pre></td></tr></table></figure>
<p>More info: <a href="https://hexo.io/docs/writing.html" target="_blank" rel="noopener">Writing</a></p>
<h3 id="Run-server"><a href="#Run-server" class="headerlink" title="Run server"></a>Run server</h3><figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">$ hexo server</span><br></pre></td></tr></table></figure>
<p>More info: <a href="https://hexo.io/docs/server.html" target="_blank" rel="noopener">Server</a></p>
<h3 id="Generate-static-files"><a href="#Generate-static-files" class="headerlink" title="Generate static files"></a>Generate static files</h3><figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">$ hexo generate</span><br></pre></td></tr></table></figure>
<p>More info: <a href="https://hexo.io/docs/generating.html" target="_blank" rel="noopener">Generating</a></p>
<h3 id="Deploy-to-remote-sites"><a href="#Deploy-to-remote-sites" class="headerlink" title="Deploy to remote sites"></a>Deploy to remote sites</h3><figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">$ hexo deploy</span><br></pre></td></tr></table></figure>
<p>More info: <a href="https://hexo.io/docs/deployment.html" target="_blank" rel="noopener">Deployment</a></p>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
      

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://clysheng.gitee.io/clysheng.oschina.me/2017/12/12/新建一个docker镜像/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Harvey">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/clysheng.oschina.me/images/jianchi.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Harvey's blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
                
                <a class="post-title-link" href="/clysheng.oschina.me/2017/12/12/新建一个docker镜像/" itemprop="url">制作一个基于集成java和tomcat的docker镜像</a></h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2017-12-12T00:00:00+08:00">
                2017-12-12
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/clysheng.oschina.me/categories/docker/" itemprop="url" rel="index">
                    <span itemprop="name">docker</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        
          
            <h2 id="根据当前所处平台安装docker"><a href="#根据当前所处平台安装docker" class="headerlink" title="根据当前所处平台安装docker"></a>根据当前所处平台安装<strong>docker</strong></h2><h2 id="准备安装java，tomcat需要的安装包"><a href="#准备安装java，tomcat需要的安装包" class="headerlink" title="准备安装java，tomcat需要的安装包"></a>准备安装java，tomcat需要的安装包</h2><h2 id="制作镜像"><a href="#制作镜像" class="headerlink" title="制作镜像"></a>制作镜像</h2><h3 id="编写DockerFile"><a href="#编写DockerFile" class="headerlink" title="编写DockerFile"></a>编写DockerFile</h3><h3 id="构建DockerFile"><a href="#构建DockerFile" class="headerlink" title="构建DockerFile"></a>构建DockerFile</h3><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker build -t java7_tomcat7:v1 .</span><br></pre></td></tr></table></figure>
<ul>
<li>java7_tomcat7：构建后镜像名字</li>
<li>v1：构建后的镜像tag</li>
<li>.：当前路径</li>
</ul>
<h3 id="查看镜像"><a href="#查看镜像" class="headerlink" title="查看镜像"></a>查看镜像</h3><p>构建成功以后可以通过<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker images</span><br></pre></td></tr></table></figure></p>
<p>查看构建成功后的镜像</p>
<h2 id="启动容器"><a href="#启动容器" class="headerlink" title="启动容器"></a>启动容器</h2><h3 id="输出一个Hello-World之后终止容器"><a href="#输出一个Hello-World之后终止容器" class="headerlink" title="输出一个Hello World之后终止容器"></a>输出一个Hello World之后终止容器</h3><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">sudo docker run ubuntu:14.04 /bin/echo &apos;Hello World&apos;</span><br></pre></td></tr></table></figure>
<h3 id="启动一个bash终端允许用户交互"><a href="#启动一个bash终端允许用户交互" class="headerlink" title="启动一个bash终端允许用户交互"></a>启动一个bash终端允许用户交互</h3><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">sudo docker run -t -i ubuntu:14.0.4 /bin/bash</span><br></pre></td></tr></table></figure>
<p>其中-t表示让Docker分配一个伪终端并绑定在标准输入,-i则表示标准输入保持打开</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">sudo docker run -t -i -p 9999:8080 ubuntu:14.0.4 /bin/bash</span><br></pre></td></tr></table></figure>
<p>-p后面的端口，表示将宿主机器的9999端口绑定到容器的8080端口，可以通过宿主机器ip+9999端口，访问容器内的服务。</p>
<h2 id="进入正在运行的容器"><a href="#进入正在运行的容器" class="headerlink" title="进入正在运行的容器"></a>进入正在运行的容器</h2><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker attach 44fc0f0582d9</span><br></pre></td></tr></table></figure>
<p>后面的字符串为容器id可以通过<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker ps</span><br></pre></td></tr></table></figure></p>
<p>查看正在运行的容器<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker ps -a</span><br></pre></td></tr></table></figure></p>
<p>查看所有的容器</p>
<h2 id="为镜像打标签"><a href="#为镜像打标签" class="headerlink" title="为镜像打标签"></a>为镜像打标签</h2><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker tag vpjr:v1 clysheng/vpjr:v1</span><br></pre></td></tr></table></figure>
<p>vpjr:v1本地镜像名字和tag名字<br>clysheng/vpjr:v1 :修改后的名字</p>
<h2 id="上传镜像到dockerhub"><a href="#上传镜像到dockerhub" class="headerlink" title="上传镜像到dockerhub"></a>上传镜像到dockerhub</h2><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker push clysheng/vpjr:v1</span><br></pre></td></tr></table></figure>
<p>可以先通过<br><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">docker login</span><br></pre></td></tr></table></figure></p>
<p>登录</p>

          
        
      
    </div>
    
    
    

    

    

    

    <footer class="post-footer">
      

      

      

      
      
        <div class="post-eof"></div>
      
    </footer>
  </div>
  
  
  
  </article>


    
  </section>

  


          </div>
          


          

        </div>
        
          
  
  <div class="sidebar-toggle">
    <div class="sidebar-toggle-line-wrap">
      <span class="sidebar-toggle-line sidebar-toggle-line-first"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-middle"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-last"></span>
    </div>
  </div>

  <aside id="sidebar" class="sidebar">
    
    <div class="sidebar-inner">

      

      

      <section class="site-overview-wrap sidebar-panel sidebar-panel-active">
        <div class="site-overview">
          <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
            
              <img class="site-author-image" itemprop="image"
                src="/clysheng.oschina.me/images/jianchi.jpg"
                alt="Harvey" />
            
              <p class="site-author-name" itemprop="name">Harvey</p>
              <p class="site-description motion-element" itemprop="description">再牛逼的梦想，也抵不过傻逼式的坚持</p>
          </div>

          <nav class="site-state motion-element">

            
              <div class="site-state-item site-state-posts">
              
                <a href="/clysheng.oschina.me/archives/">
              
                  <span class="site-state-item-count">10</span>
                  <span class="site-state-item-name">日志</span>
                </a>
              </div>
            

            
              
              
              <div class="site-state-item site-state-categories">
                <a href="/clysheng.oschina.me/categories/index.html">
                  <span class="site-state-item-count">6</span>
                  <span class="site-state-item-name">分类</span>
                </a>
              </div>
            

            
              
              
              <div class="site-state-item site-state-tags">
                <a href="/clysheng.oschina.me/tags/index.html">
                  <span class="site-state-item-count">9</span>
                  <span class="site-state-item-name">标签</span>
                </a>
              </div>
            

          </nav>

          

          

          
          

          
          
            <div class="links-of-blogroll motion-element links-of-blogroll-inline">
              <div class="links-of-blogroll-title">
                <i class="fa  fa-fw fa-link"></i>
                Links
              </div>
              <ul class="links-of-blogroll-list">
                
                  <li class="links-of-blogroll-item">
                    <a href="http://tengj.top/" title="嘟嘟独立博客" target="_blank">嘟嘟独立博客</a>
                  </li>
                
                  <li class="links-of-blogroll-item">
                    <a href="http://fubin.org.cn/" title="Fubin's Blog" target="_blank">Fubin's Blog</a>
                  </li>
                
              </ul>
            </div>
          

          

        </div>
      </section>

      

      

    </div>
  </aside>


        
      </div>
    </main>

    <footer id="footer" class="footer">
      <div class="footer-inner">
        <script async src="https://dn-lbstatics.qbox.me/busuanzi/2.3/busuanzi.pure.mini.js"></script>
<div class="copyright">&copy; <span itemprop="copyrightYear">2018</span>
  <span class="with-love">
    <i class="fa fa-user"></i>
  </span>
  <span class="author" itemprop="copyrightHolder">Harvey</span>

  
</div>




<div>
  本站总访问量<span id="busuanzi_value_site_pv"></span>次
  本站访客数<span id="busuanzi_value_site_uv"></span>人次
</div>




        
<div class="busuanzi-count">
  <script async src="https://dn-lbstatics.qbox.me/busuanzi/2.3/busuanzi.pure.mini.js"></script>

  

  
</div>








        
      </div>
    </footer>

    
      <div class="back-to-top">
        <i class="fa fa-arrow-up"></i>
        
      </div>
    

    

  </div>

  

<script type="text/javascript">
  if (Object.prototype.toString.call(window.Promise) !== '[object Function]') {
    window.Promise = null;
  }
</script>









  


  











  
  
    <script type="text/javascript" src="/clysheng.oschina.me/lib/jquery/index.js?v=2.1.3"></script>
  

  
  
    <script type="text/javascript" src="/clysheng.oschina.me/lib/fastclick/lib/fastclick.min.js?v=1.0.6"></script>
  

  
  
    <script type="text/javascript" src="/clysheng.oschina.me/lib/jquery_lazyload/jquery.lazyload.js?v=1.9.7"></script>
  

  
  
    <script type="text/javascript" src="/clysheng.oschina.me/lib/velocity/velocity.min.js?v=1.2.1"></script>
  

  
  
    <script type="text/javascript" src="/clysheng.oschina.me/lib/velocity/velocity.ui.min.js?v=1.2.1"></script>
  

  
  
    <script type="text/javascript" src="/clysheng.oschina.me/lib/fancybox/source/jquery.fancybox.pack.js?v=2.1.5"></script>
  

  
  
    <script type="text/javascript" src="/clysheng.oschina.me/lib/canvas-nest/canvas-nest.min.js"></script>
  


  


  <script type="text/javascript" src="/clysheng.oschina.me/js/src/utils.js?v=5.1.3"></script>

  <script type="text/javascript" src="/clysheng.oschina.me/js/src/motion.js?v=5.1.3"></script>



  
  


  <script type="text/javascript" src="/clysheng.oschina.me/js/src/affix.js?v=5.1.3"></script>

  <script type="text/javascript" src="/clysheng.oschina.me/js/src/schemes/pisces.js?v=5.1.3"></script>



  

  


  <script type="text/javascript" src="/clysheng.oschina.me/js/src/bootstrap.js?v=5.1.3"></script>



  


  




	





  





  












  




  
  
  
  <link rel="stylesheet" href="/clysheng.oschina.me/lib/algolia-instant-search/instantsearch.min.css">

  
  
  <script src="/clysheng.oschina.me/lib/algolia-instant-search/instantsearch.min.js"></script>
  

  <script src="/clysheng.oschina.me/js/src/algolia-search.js?v=5.1.3"></script>



  

  

  

  
  

  

  

  




</body>
</html>
